#!/usr/bin/env node


const cp=require('child_process');

//父进程和子进程分离

let child=cp.spawn('./03-child.js',[],{detach:true,stdio:['ignore',1,2]});

//child.stdout.pipe(process.stdout);


//释放指针 释放子进程
child.unref();

console.log(`I am father Process:${process.pid}`);

setTimeout(()=>{
  console.log('Goodbye');
  process.exit();

},5000);
